Optimal. Leaf size=16 \[ b \log (x)-\frac{a x^{-n}}{n} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0055173, antiderivative size = 16, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 15, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.067, Rules used = {14} \[ b \log (x)-\frac{a x^{-n}}{n} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 14
Rubi steps
\begin{align*} \int x^{-1-n} \left (a+b x^n\right ) \, dx &=\int \left (\frac{b}{x}+a x^{-1-n}\right ) \, dx\\ &=-\frac{a x^{-n}}{n}+b \log (x)\\ \end{align*}
Mathematica [A] time = 0.0097582, size = 16, normalized size = 1. \[ b \log (x)-\frac{a x^{-n}}{n} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.01, size = 25, normalized size = 1.6 \begin{align*}{\frac{1}{{{\rm e}^{n\ln \left ( x \right ) }}} \left ( b\ln \left ( x \right ){{\rm e}^{n\ln \left ( x \right ) }}-{\frac{a}{n}} \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.01863, size = 41, normalized size = 2.56 \begin{align*} \frac{b n x^{n} \log \left (x\right ) - a}{n x^{n}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 14.4492, size = 107, normalized size = 6.69 \begin{align*} \begin{cases} a x + b \log{\left (x \right )} & \text{for}\: n = -1 \\\left (a + b\right ) \log{\left (x \right )} & \text{for}\: n = 0 \\- \frac{a n}{n^{2} x^{n} + n x^{n}} - \frac{a}{n^{2} x^{n} + n x^{n}} + \frac{b n^{2} x^{n} \log{\left (x \right )}}{n^{2} x^{n} + n x^{n}} + \frac{b n x^{n} \log{\left (x \right )}}{n^{2} x^{n} + n x^{n}} + \frac{b n x^{n}}{n^{2} x^{n} + n x^{n}} & \text{otherwise} \end{cases} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.15774, size = 28, normalized size = 1.75 \begin{align*} \frac{b n x^{n} \log \left (x\right ) - a}{n x^{n}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]